<template>
  <view class="content">
    <image class="logo" src="@img/logo.png" />
    <view class="text-area">
      <text class="title">{{ title }}</text>
    </view>
    <button type="primary" @tap="topage" > 跳转分包 {{ $filters.userEnumerate(2) }} </button>
    <confirm v-model="PageData.showConfrim" @rightClons="rightClons"></confirm>
  </view>
</template>

<script setup lang="ts">

 let { proxy } = getCurrentInstance() as ComponentInternalInstance
// const title = ref('Hello')
const PageData = reactive({
  showConfrim: false
})

 onShow(() => {
 Toast('hahahhahah')

 SetStorage('titile', 1111111111)

 console.log(import.meta.env, proxy)

 })

 onLoad(async()=>{
   await getApp().globalData!.SystemInitialization // 等待初始化完成后在执行后面的逻辑
   console.log(getApp(),'getapp')
 })

 function topage() {
  //PageData.showConfrim = true
   //uni.navigateTo({ url: '/pages/subpackage/details/details'})
   PostAll('http://localhost:3339/user/list')
}



function rightClons() {
  console.log('rightClons')
  PageData.showConfrim = false
}
</script>

<style>
.content {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.logo {
  height: 200rpx;
  width: 200rpx;
  margin-top: 200rpx;
  margin-left: auto;
  margin-right: auto;
  margin-bottom: 50rpx;
}

.text-area {
  display: flex;
  justify-content: center;
}

.title {
  font-size: 36rpx;
  color: #8f8f94;
}
</style>
